package com.hll;

import java.io.File;
import java.io.FileWriter;
import java.io.IOException;
import java.lang.management.ManagementFactory;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import springfox.documentation.swagger2.annotations.EnableSwagger2;

@SpringBootApplication
@EnableSwagger2
public class Main {


	public static void main(String[] args) throws IOException {
		//pid 方便 用kill关闭
		String name = ManagementFactory.getRuntimeMXBean().getName().split("@")[0];
		FileWriter writer=new FileWriter(new File("main.pid"));
		writer.write(name);
		writer.close();
		
		SpringApplication.run(Main.class);
	}


}
